import ILoginForm from '@/model/form/user/ILoginForm'
import IResVO from '@/model/vo/common/IResVO'
import $http from '@/util/http'
import { AxiosResponse } from 'axios'

// 登录接口
export default function loginApi(form: ILoginForm) {
  return $http.post<IResVO, AxiosResponse<IResVO>, ILoginForm>('/login', form, {
    timeout: 10000,
    headers: {
      hiddenErrorMsg: true, // 隐藏接口请求报错提示
    },
  })
}
